﻿
#pragma once

#include "poco/Net/TCPServerConnectionFactory.h"
#include "CNewConnection.h"
#include "poco/Net/StreamSocket.h"
#include <fmt/format.h>
#include <spdlog/logger.h>

class CNewConnectionFactory :public Poco::Net::TCPServerConnectionFactory
{
public:
	CNewConnectionFactory() {
	}

	~CNewConnectionFactory() {
	}

	//重写基类函数，创建连接实例
	CNewConnection* createConnection(const Poco::Net::StreamSocket& socket) {
		return new CNewConnection(socket);
	}
};

